﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Frontend/Frontend.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<IntroduceCompany.QuestionView>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<!--title menu-->
    <table border="0" cellpadding="0" cellspacing="0" width="100% ;">
        <tr>
            <td class="col-left">
                <!--Content left here-->
            </td>
            <td class="col-center">
                <div class="survey">
                    <% using (Html.BeginForm("Poll", "Survey", FormMethod.Post)){%>
                        <%  IQueryable<IntroduceCompany.AnswerView> answerList;
                        int questionNo = 1;
                        foreach (var item in Model){ %>
                        <div>
                            <div class="survey_fl">
                                <p class="items"><%= IntroduceCompany.Resources.Resx.Frontend_Survey_SurveyPage_lab_Question%> <%= questionNo++%>:</p>
                            </div>
                            <div class="survey_fr">
                                <p><%= Html.Encode(item.QuestionContent)%><br />
                                <%  answerList = IntroduceCompany.Singleton.DataSingleton.GetSurveyModels().GetAnswerList_Frontend(item.QuestionID, item.LanguageID);
                                   foreach (var item2 in answerList)
                                   { %>
                                        <input type="checkbox" id="<%= item2.AnswerID%>" name="<%= item2.AnswerID%>" value="true_true"  />
                                        <%= Html.Encode(item2.AnswerContent)%><br />
                                 <%} %>
                                 </p>
                            </div>
                        </div>
                        <% }%>
                        <div>
                            <div class="survey_fr" style="margin-left:80px;">
                                <p><label><%= IntroduceCompany.Resources.Resx.FeedbackCreate_lab_Captcha%>:</label><br /><%= Html.TextBox("captchaValue",null, new { @style="width:100px;"})%><img src="/vi/Captcha/Show" alt="" style="height:20px;"/><br /><span class="notice"><%= Html.ValidationMessage("Notice")%></span></p>
                                <input type="submit" value="<%= IntroduceCompany.Resources.Resx.Frontend_Survey_SurveyPage_btn_Update%>" />
                                <a href="<%= Url.Action("ResultPage", "Survey") %>" class="button"><%= IntroduceCompany.Resources.Resx.Frontend_Survey_SurveyPage_lab_result%></a>
                            </div>
                        </div>
                  <%} %>
                </div>
            </td>
        </tr>
    </table>
</asp:Content>
